<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ taglib prefix="shiro" uri="http://shiro.apache.org/tags"%>
<c:set var="ctx" value="${pageContext.request.contextPath}" />
<link rel="stylesheet" href="${ctx}/resources/js/autoComplete/flexselect.css" type="text/css" media="screen" />
<script src="${ctx}/resources/js/autoComplete/liquidmetal.js" type="text/javascript"></script>
<script src="${ctx}/resources/js/autoComplete/jquery.flexselect.js" type="text/javascript"></script>
<script type="text/javascript">
        $(function(){
            $(".airport_list").css("width","13px");
        });
    </script>
<!-- 顶部模块[如：功能按钮、搜索面板] -->
<div class="bjui-pageContent" style="background: #FFF;">
	<form id="pagerForm" data-toggle="validate" class="ajaxForm" action="${ctx}/bus/airportAction/doSave" method="post" >
		<input type="hidden" name="op" id="j_dialog_op"value="${param.op}${op}">
		<input type="hidden" name="id"id="j_dialog_id" value="${airport.id}">
		<table id="doc-datagrid-table"
			class="table table-bordered table-hover table-striped table-top">
			<tbody>
				 <tr>
                    <td colspan="2" align="center" valign="middle"><h4>${title}</h4></td>
                </tr>
				<tr style="height: 30px;">
					<td>
					<label for="name" class="control-label x90">机场简称：</label>
							<input name="airportAbbreName"  value="${airport.airportAbbreName}" data-rule="required;">
					<label for="name" class="control-label x90">机场中文名称：</label>
							<input name="airportChName" value="${airport.airportChName}" data-rule="required;">
					</td>
				</tr>
				<tr style="height: 30px;">
					<td>
						<label for="name" class="control-label x90">机场英文名称：</label>
							<input name="airportEnName" value="${airport.airportEnName}" data-rule="required;">
						<label for="name" class="control-label x90">机场三字码：</label>
							<input name="airport3Code" value="${airport.airport3Code}" data-rule="required;">
					</td>
				</tr>
				<tr style="height: 30px;">
					<td>
						<label for="name" class="control-label x90">机场四字码：</label>
							<input name="airport4Code" value="${airport.airport4Code}" data-rule="required;">
						<label for="name" class="control-label x90">是否热门：</label>
							<select data-toggle="selectpicker" name="isHot" data-rule="required;" >
								<c:forEach items="${whetherList}"  var="c">
										<c:choose>
											<c:when test="${airport.isHot ==c.codeValue}">
												<option value="${c.codeValue}" selected >${c.codeName}</option>
											</c:when>
											<c:otherwise>
												<option value="${c.codeValue}" >${c.codeName}</option>
											</c:otherwise>
										</c:choose>
								</c:forEach>
							</select>
					</td>
				</tr>
				 <tr>
                     <td>
                        <label class="control-label x90">所属城市：</label>
                          <select class="special-flexselect" name="cityCode" tabindex="1" data-placeholder="请输入所属城市" data-rule="required;">
					          <c:forEach  items= "${citys}" var="c">
					            	<option value="${c.cityCode}" ${airport.cityCode == c.cityCode?"selected='selected'":""} >${c.cityCnName}</option>					            
				              </c:forEach>
					       </select>
                    	<script type="text/javascript">
					      $(document).ready(function() {
					        $("select.special-flexselect").flexselect({ hideDropdownOnEmptyInput: true });
					      }); 
					    </script>
                    </td>
                </tr>
				 <tr>
                	<td colspan="2">
                        <label for="description" class="control-label x90">机场介绍：</label>
                        <textarea name="airportIntroduce" id="airportIntroduce" rows="5" cols="58" >${airport.airportIntroduce}</textarea>
                    </td>
                </tr>
			</tbody>
		</table>
	</form>


</div>

<!-- 底部模块[如：工具条、分页组件]  -->
<div class="bjui-pageFooter">
	<ul>
		<li><button type="button" class="btn-close" data-icon="close">关闭</button></li>
		<li><button type="submit" class="btn-default" data-icon="save">保存</button></li>
	</ul>

</div>
